package com.simon.zhujie;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

/**
 * Created by changf on 2017/7/13.
 */
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = "classpath:spring1.xml")
@Component
public class AnnotationTest {
    @Autowired
    UserSevice userSevice;

    @Test
public void testSay(){
    userSevice.say("zhangfei");

}
}
